<!DOCTYPE html>
<html>
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
		<title>顶牛热点概念解析</title>
		<link href="newskin/index.css" rel="stylesheet" type="text/css" />
		
		<style>		
			.fixedBox{					
				white-space: nowrap;	
			}
			.fixedBox::-webkit-scrollbar {
				width: 12px;     
				height: 12px;				
			}			
			
		</style>
		<script type="text/javascript" src="js/json2html.js"></script>
		<script type="text/javascript" src="js/jquery.min.js"></script>
		<script>
			window.onload = function() {
			getSource();
			//changeStyle();
			}
						
			function time_range(beginTime, endTime) {
				var strb = beginTime.split(":");
				if (strb.length != 2) {
					return false;
				}

				var stre = endTime.split(":");
				if (stre.length != 2) {
					return false;
				}

				var b = new Date();
				var e = new Date();
				var n = new Date();

				b.setHours(strb[0]);
				b.setMinutes(strb[1]);
				e.setHours(stre[0]);
				e.setMinutes(stre[1]);

				if (n.getTime() - b.getTime() > 0 && n.getTime() - e.getTime() < 0) {
					getSource();					
					console.log(true)　　　　　　
					return true;				
				} else {
					console.log(false)
				    return false;     
				}
			}　　　
   　　　
			$(function() {
				setInterval(function() {
				time_range("9:00","15:15")						
				},
				60000);
			})
						
			function changeStyle() {
				var obj = document.getElementById("towrite");	
				obj.style.left= "0px"; 				
				obj.style.width= "500px";	
				obj.style.height= "330px";										  			 
			}					
						
			
			function createXmlHttp() {
				if (window.XMLHttpRequest) {
				xmlHttp1 = new XMLHttpRequest();				
				} else {
				xmlHttp1 = new ActiveXObject("Microsoft.XMLHTTP");				
				}
			}
			
			function getSource() {	    							
				var url1 = "http://www.dingniugu.com/gainianjiexi.html"; 
				createXmlHttp();				
				xmlHttp1.onreadystatechange = writeSource;
				xmlHttp1.open("GET", url1, true);
				xmlHttp1.send(null);				
			}
			
			
			function writeSource() { 
				if (xmlHttp1.readyState == 4) { 					
					div1 = document.getElementById('towrite');					
					var data1 = xmlHttp1.responseText
					//document.write(data1);
					
					data1 = '<div class="bodyrd">' + data1.substring(data1.indexOf('<div class="box_sorttit">'),data1.indexOf('<em>全面涵盖各行业热点概念 可使用 <b>ctrl+F</b> 进行页面搜索</em>'));					
					data1 = data1.replace(/\"\/newskin/g,'\"newskin').replace(/\"\/newdata/g,'\"newskin');
					data1 = data1.replace(/<a href=\"\/dde\//g,'<a href=\"http:\/\/www.treeid\/code_').replace(/.html/g,'').replace(/target=\"_blank\"/g,'');
					data1 = data1.replace(/(a href=\").*?(title)/g,function(word){ return 'a href=\"\" title';});
					//document.write(data1);
					
					//div1.innerText = data1;	
					
					div1.innerHTML = data1;
					//alert(bk);
				}				
			}
			
			
		</script>
	</head>
	<body>
		<div id="towrite" class="fixedBox">			
	</body>
</html>